package com.example.studentregistration.mapper;

import com.example.studentregistration.pojo.DormRoom;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
public interface DormRoomMapper {
    int insert(DormRoom entity);
    int update(DormRoom entity);
    int delete(Integer id);
    DormRoom findById(Integer id);
    DormRoom findByBuildingAndRoomNo(@Param("buildingId") Integer buildingId, @Param("roomNo") String roomNo);
    List<DormRoom> findByBuildingId(Integer buildingId);
    List<DormRoom> findAll();
    int batchDelete(@Param("ids") List<Integer> ids);
}